#include <iostream>
#include <vector>
using namespace std;

//1,1,2,3,5,8,13动态规划求斐波那契数列

int func(int n)
{
    vector<int> dp(n + 1,0);
    dp[0] = 1;
    dp[1] = 1;
    dp[2] = 2;
    for(int i = 3;i <= n;i++)
    {
        dp[i] = dp[i - 1] + dp[i -2];
    }
    return dp[n];
}
int main()
{
    const int n = 6;
    int result = func(n);
    cout << result << endl;
}